﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Admin.Master" AutoEventWireup="true" CodeBehind="adminAuthorDetail.aspx.cs" Inherits="LibrarySystem.WebForm10" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="mainContent" runat="server">
     <asp:Label ID="authorDetailName" runat="server"></asp:Label>
    <asp:Label ID="authorDetailYear" runat="server"></asp:Label>
    <br /> <br />
    <asp:Label ID="authorDetailCount" runat="server" CssClass="labels"></asp:Label>
    <asp:ListView ID="bookDetailCopyList" runat="server">
        <LayoutTemplate> 
             <tbody> <asp:PlaceHolder runat="server" ID="itemPlaceholder" /> </tbody>
        </LayoutTemplate>
        <ItemTemplate>    
            <asp:LinkButton ID="LinkButton1"  runat="server" OnCommand="listItem_ClickedBook" CssClass="linkBtnBook" CommandName='<%#Eval("ISBN")%>'>        
                <table id="bookDetailCopies"> <tr><td id="bookDetailOne"><%# Eval("Title") %> </td><td id="bookDetailTwo">ISBN: <%# Eval("ISBN") %></td></tr></table>
                </asp:LinkButton>
        </ItemTemplate>        
    </asp:ListView>

    <div id="adminControlDiv">
        <div id="adminControls">
            <asp:Button ID="adminCtrlModify" runat="server" CssClass="adminModify" Text="Modifiera" OnClick="adminCtrlModify_Click" />
            <asp:Button ID="adminCtrlRemove" runat="server" CssClass="adminDelete" Text="Ta bort" OnClick="adminCtrlRemove_Click" />
        </div>

        <asp:Panel id="adminModify" CssClass="adminPanel" runat="server" Visible="false">
            <asp:Label runat="server">Förnamn: 
            <asp:TextBox ID="modifyFirstName" runat="server"></asp:TextBox></asp:Label><br />
            <asp:Label runat="server">Efternamn: 
            <asp:TextBox ID="modifyLastName" runat="server"></asp:TextBox></asp:Label><br />
            <asp:Label  runat="server" >Födelseår: 
            <asp:TextBox ID="modifyBirth" runat="server"></asp:TextBox></asp:Label><br />
            <asp:Button ID="adminCtrlSave" runat="server" CssClass="adminSave" Text="Spara" OnClick="adminCtrlSave_Click" />
        </asp:Panel>
    </div>
</asp:Content>
